
const local = {
    set:function(key,value){
        localStorage.setItem(key,JSON.stringify(value))
    },
    get:function(key){
       let str = JSON.parse(localStorage.getItem(key))
       return str;
    },
    remove:function(key){
        localStorage.removeItem(key)
    },
    clear:function(){
        localStorage.clear()
    }

}
window.local = local;